import { Router } from 'express';
import { getStudyGoals, getStudyGoal, createStudyGoal, updateStudyGoal, deleteStudyGoal } from '../controllers/studyGoalController';
import { auth } from '../middlewares/auth';

const router = Router();

// 获取学习目标列表
router.get('/', auth, getStudyGoals);

// 获取单个学习目标
router.get('/:id', auth, getStudyGoal);

// 创建学习目标
router.post('/', auth, createStudyGoal);

// 更新学习目标
router.put('/:id', auth, updateStudyGoal);

// 删除学习目标
router.delete('/:id', auth, deleteStudyGoal);

export default router; 